//
//  CTVConfigMenuController.h
//  Channltv
//
//  Created by Bruno  Keymolen on 19/07/07.
//  Copyright 2007 channl.tv. All rights reserved.
//

#import <Cocoa/Cocoa.h>
#import <BackRow/BackRow.h>
#import "CTVConfigElement.h"
#import "CTVAutoUpdate.h"


@interface CTVConfigMenuController : BRMediaMenuController <CTVAutoUpdateListener>  {
	NSMutableArray* m_configElements;
	int m_oldAutoSyncMinutes;
	BOOL m_el1;
	BOOL m_er1;
	BOOL m_el2;
	
}

- (id) initWithScene: (BRRenderScene *) scene;
- (void) dealloc;

- (long) itemCount;
- (id<BRMenuItemLayer>) itemForRow: (long) row;
- (NSString *) titleForRow: (long) row;
- (long) rowForTitle: (NSString *) title;

- (void) itemSelected: (long) row;

- (id<BRMediaPreviewController>) previewControllerForItem: (long) item;

- (BOOL)brEventAction:(BREvent*)event;


-(void)configCTVSelectionYN:(CTVConfigElement*)configElement;
-(void)configCTVSelectionUnSyncUserText:(CTVConfigElement*)configElement;
-(void)configCTVSelectionPasswordText:(CTVConfigElement*)configElement;
-(void)configCTVAutoSync:(CTVConfigElement*)configElement;
-(void)configCTVTextEditDone:(NSNotification*)note;
-(void)configCTVCheckUpdates:(CTVConfigElement*)menuelement;
-(void)showAbout:(CTVConfigElement*)menuelement;
-(void)configCTVCleanCache:(CTVConfigElement*)menuelement;


- (void) menuTest:(CTVConfigElement*)menuelement;


//AutoUpdateListener
-(void)autoUpdateCheckDone:(NSString*)version;	
-(void)autoUpdateCheckFail;		

@end
